import http from "@/utils/http";
//获取表格数据列表
export const getList = (params) => {
  return http.post("/pro/init/list", params);
};
//获取数据统计
export const getCount = (params) => {
  return http.get("/pro/init/groups", params);
};
//新增/编辑
export const editRecords = (params) => {
  return http.post(`/pro/init/saveZxBase`, params);
};
//删除
export const delRecords = (params) => {
  return http.get(`/pro/init/delInfos`, params);
};
//获取项目基础信息
export const baseDetail = (id) => {
  return http.get(`/pro/init/base/${id}`);
};
//获取各tab上方展示的基础信息
export const baseInfo = (params) => {
  return http.get(`/pro/init/otherBase`, params);
};
//获取项目成员信息
export const memberDetail = (params) => {
  return http.get("/pro/init/member", params);
};
//编辑项目成员信息
export const editMember = (params) => {
  return http.post(`/pro/init/saveZxMember`, params);
};
//获取合作单位信息
export const unitDetail = (id) => {
  return http.get(`/pro/init/cooperationUnit/${id}`);
};
//编辑合作单位信息
export const editUnit = (params) => {
  return http.post(`/pro/init/saveZxUnit`, params);
};
//获取校内课题信息
export const schoolSubjectDetail = (id) => {
  return http.get(`/pro/init/keti/${id}`);
};
//编辑校内课题信息
export const editSchoolSubject = (params) => {
  return http.post(`/pro/init/saveZxKeti`, params);
};
//获取项目文档信息
export const documentDetail = (id) => {
  return http.get(`/pro/init/document/${id}`);
};
//编辑项目文档信息
export const editDocument = (params) => {
  return http.post(`/pro/init/saveZxFile`, params);
};
//获取项目预算信息
export const budgetDetail = (params) => {
  return http.get("/pro/init/budget", params);
};
//编辑预算信息
export const editBudget = (params) => {
  return http.post(`/pro/init/saveBudget`, params);
};
//获取项目经费数据
export const feeDetail = (id) => {
  return http.get(`/pro/init/money/${id}`);
};
//获取出账合同数据
export const contractDetail = (id) => {
  return http.get(`/pro/init/buyer/${id}`);
};
//获取衍生成果数据
export const achievementDetail = (id) => {
  return http.get(`/pro/init/achievement/${id}`);
};
//获取执行过程数据
export const processDetail = (id) => {
  return http.get(`/pro/init/process/${id}`);
};
//提交和保存并通过
export const saveOrCheckOk = (params) => {
  return http.get("/pro/init/saveAndCheck", params);
};
//导出项目信息
export const exportRecords = (params = {}) => {
  return http.post("/pro/init/export", params, {
    responseType: "blob",
  });
};
